package net.edu_soft.ec.asset.mapper;

import java.util.List;
import net.edu_soft.ec.asset.pojo.Audit;
import net.edu_soft.ec.asset.pojo.AuditExample;
import net.edu_soft.ec.asset.pojo.ResultType;
import net.edu_soft.ec.asset.pojo.bo.AuditBO;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

@Repository
public interface AuditMapper {
    long countByExample(AuditExample example);

    int deleteByExample(AuditExample example);

    int deleteByPrimaryKey(Integer auditId);

    int insert(Audit record);

    int insertSelective(Audit record);

    List<Audit> selectByExample(AuditExample example);

    Audit selectByPrimaryKey(Integer auditId);

    int updateByExampleSelective(@Param("record") Audit record, @Param("example") AuditExample example);

    int updateByExample(@Param("record") Audit record, @Param("example") AuditExample example);

    int updateByPrimaryKeySelective(Audit record);

    int updateByPrimaryKey(Audit record);

    /***
     * in查询产品名集合
     * @param list 产品id集合
     * @return
     */
    List<ResultType> selProNames(List<Integer> list);


    /***
     * in查询产品名集合
     * @param list 产品id集合
     * @return
     */
    List<ResultType> selFacNames(List<Integer> list);


    /***
     * in查询产品名集合
     * @param list 产品id集合
     * @return
     */
    List<ResultType> selApplyNames(List<Integer> list);

    /***
     * 批量修改审核主体状态，需为一样的状态，例如全部审核成功，全部审核失败
     * @param auditBO 审核参数类
     * @return
     */
    int updateSubsStatus(AuditBO auditBO);
}